package com.totoro.service;

import com.totoro.pojo.*;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * @author TOTORO
 * @date 2021/7/19 10:01
 */
public interface OrderService {

    MarketOrder generateOrdersPojo(int userId, int sid, int arid, int orderStatus);

    Integer addMarketOrder(MarketOrder marketOrder);

    Integer addMarketSrOrder(MarketSrOrder marketSrOrder);

    Integer updateMarketOrderPrevStatus(int status, String marketOdd);

    Map<String, OrderTimeline> findOrderTimeLineByMid(@Param("mid") int mid);

    Integer addOrderTimeLineByMid(OrderTimeline orderTimeline);

    MarketOrder findMarketOrderByMarketOdd(String marketOdd);

    List<MarketOrder> findAllOrder(Object id, Integer findType, Integer status);

    List<MarketOrder> superFindUserOrderId(BuyerOrderFind buyerOrderFind);

    Integer falseDeleteOrder(int moId);

    List<MarketOrder> findRecoverOrder(int uid, int curr);

    Integer[] notPaginationRecoverOrder(int uid, int curr);

    Integer trueDeleteOrder(int[] moIds);

    Integer reductionOrder(int[] moIds);

    List<MarketOrder> superFindSellerOrderId(SellerOrderFind sellerOrderFind);

    Integer updateOrder(MarketOrder marketOrder);

    Integer updateSrOrderPayPrice(int msroId, double payPrice);

    Integer updateOrderAllPrice(int moId, double allPrice);

    Integer updateMarketSrOrderCommentStatus(int msroId);

    Integer updateMarketSrOrderAppendCommentStatus(int msroId);

    MarketOrder findMarketByMarketSrOrderId(int msroId);

    MarketSrOrder findMarketSrOrderByMsroId(int msroId);

    Integer updateMarketSrReturnStatus(int status, int status2, int msroId);
}
